package com.cn.springcloudwechat.service;


import com.cn.springcloudwechat.model.YmUserCollection;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

public interface YmUserCollectionService {

    /**
     * 收藏课程查询
     * @param userId
     * @return
     */
    List<Map<String,Object>> getCourse(Long userId);

    /**
     * 收藏文章查询
     * @param userId
     * @return
     */
    List<Map<String,Object>> getGraphic(Long userId);

    /**
     * 收藏
     * @param ymUserCollection
     * @return
     */
    Integer insertCollection( String collectionType,
                              Long collectionTypeId, Long userId);

    /**
     * 取消收藏
     * @param collectionId
     * @return
     */
    Integer deleteCollectionState(  Long collectionTypeId,Long userId);

    /**
     * 是否已收藏查询
     * @param collectionTypeId
     * @return
     */
    Integer getRepeat( Long collectionTypeId,Long userId);

}
